package com.acdc.business.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.acdc.business.mapper.RechargeRecordMapper;
import com.acdc.business.domain.RechargeRecord;
import com.acdc.business.service.IRechargeRecordService;

/**
 * 用户充值记录Service业务层处理
 * 
 * @author acdc
 * @date 2025-08-26
 */
@Service
public class RechargeRecordServiceImpl implements IRechargeRecordService 
{
    @Autowired
    private RechargeRecordMapper rechargeRecordMapper;

    /**
     * 查询用户充值记录
     * 
     * @param id 用户充值记录主键
     * @return 用户充值记录
     */
    @Override
    public RechargeRecord selectRechargeRecordById(Long id)
    {
        return rechargeRecordMapper.selectRechargeRecordById(id);
    }

    /**
     * 查询用户充值记录列表
     * 
     * @param rechargeRecord 用户充值记录
     * @return 用户充值记录
     */
    @Override
    public List<RechargeRecord> selectRechargeRecordList(RechargeRecord rechargeRecord)
    {
        return rechargeRecordMapper.selectRechargeRecordList(rechargeRecord);
    }

    /**
     * 新增用户充值记录
     * 
     * @param rechargeRecord 用户充值记录
     * @return 结果
     */
    @Override
    public int insertRechargeRecord(RechargeRecord rechargeRecord)
    {
        return rechargeRecordMapper.insertRechargeRecord(rechargeRecord);
    }

    /**
     * 修改用户充值记录
     * 
     * @param rechargeRecord 用户充值记录
     * @return 结果
     */
    @Override
    public int updateRechargeRecord(RechargeRecord rechargeRecord)
    {
        return rechargeRecordMapper.updateRechargeRecord(rechargeRecord);
    }

    /**
     * 批量删除用户充值记录
     * 
     * @param ids 需要删除的用户充值记录主键
     * @return 结果
     */
    @Override
    public int deleteRechargeRecordByIds(Long[] ids)
    {
        return rechargeRecordMapper.deleteRechargeRecordByIds(ids);
    }

    /**
     * 删除用户充值记录信息
     * 
     * @param id 用户充值记录主键
     * @return 结果
     */
    @Override
    public int deleteRechargeRecordById(Long id)
    {
        return rechargeRecordMapper.deleteRechargeRecordById(id);
    }

    @Override
    public RechargeRecord selectRechargeRecordByOrderId(String orderId)
    {
        return rechargeRecordMapper.selectRechargeRecordByOrderId(orderId);
    }
}
